<template>
    <TimeChartComponent :num="data" :time="time"/>
    <TimeChartService  :onEvent="receiveNum" :onPickEvent="pickTime"/>
</template>

<script>
import TimeChartComponent from './base/TimeChartComponent.vue'
import TimeChartService from './operate/TimeChartService.vue'

export default {
    components: {
        TimeChartComponent,
        TimeChartService
    },
    data() {
        return {
            data:0,
            time:'2024-08-02'
        }
    },
    methods: {
        receiveNum(value) {
            this.data = value
            console.log("数量", value)
        },
        pickTime(value) {
            this.time = value
            console.log("时间：" + value)
        }
    }
    
}
</script>
